home *** CD-ROM | disk | FTP | other *** search
/ PsL Monthly 1993 December / PSL Monthly Shareware CD-ROM (December 1993).iso / prgmming / dos / pascal / keymakr.exe / lha / TESTNK.PAS < prev   
Pascal/Delphi Source File  |  1990-10-02  |  1KB  |  54 lines

  1. program  testkm;
  2. uses NameKey, crt, readttt5, fastttt5, iottt5;
  3. { If you do not have the TTT toolbox remove readttt5, fasttt5, iottt5
  4.   from the USES statement.}
  5.  
  6. var
  7.    name : String;
  8.    key  : String;
  9.    ans  : Boolean;
  10.  
  11. begin
  12.    Clrscr;
  13.  
  14.                                   { NON-TTT - remove from here to }
  15.    Create_Fields(1);
  16.    Set_Default_Rules(AllowNull+JumpIfFull);
  17.  
  18.    Add_Field(1,1,1,1,1,20,5);
  19.    String_Field(1,name,'***************************************');
  20.                                   {here}
  21.  
  22.    Repeat
  23.       Clrscr;
  24.                                   { NON-TTT - remove from here to }
  25.       WriteAt(13,5,White,Black,'Name:');
  26.       Display_All_Fields;
  27.       Process_Input(1);
  28.                                   {here}
  29.                                   {non-ttt replace previous code with
  30.    GotoXY(13,5); Write('Name:');
  31.    GotoXY(13,11); readln(name);
  32.                                    this}
  33.       key := NameToKey(name);
  34.  
  35.       GotoXY(12,13);   writeln(key);
  36.  
  37.                                   {NON-TTT - remove from here }
  38.    Read_YN(25,22,'Again? ',1,ans)
  39.                                   {to here}
  40.  
  41.                                   {non-ttt replace previous code with
  42.    while((ans <> 'Y') or (ans <> 'N')) do
  43.    begin
  44.       ans := 'Y'
  45.       GotoXY(25,22) Write('Again? Y');
  46.       GotoXY(25,29) Readln(ans);
  47.       UpCase(ans);
  48.    end;
  49.                                   this}
  50.  
  51.    Until(not ans);
  52.    Clrscr;
  53. end.
  54.